package mysql;

import javax.servlet.ServletContextEvent;

/**
 * @author DASK
 * @date 2020/4/2 12:53
 * @description //TODO 容器上下文监听器负责管理连接
 */
public class ServletContextListener implements javax.servlet.ServletContextListener {
    @Override
    public void contextInitialized(ServletContextEvent sce) {
        MySQLPool.initPool();
    }

    @Override
    public void contextDestroyed(ServletContextEvent sce) {
        MySQLPool.releasePool();
    }
}
